package com.earthchen.demo.tasks;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.stereotype.Service;

/**
 * @author earthchen
 * @date 2018/9/2
 **/
@Service
@EnableScheduling
public class CoreTask {

    private Logger logger = LoggerFactory.getLogger(CoreTask.class);


    /**
     * 定时任务测试
     */
//    @Scheduled(cron = "0/10 * * * * ?")
    public void testCron() {
        logger.info("定时任务测试{}" + System.currentTimeMillis());
    }
}
